package oop多态作业;

public class TestGraph {
    public static void main(String[] args) {
        Graph graph;
        graph=new Circle(2,3,5);
        graph.area();
        graph.perimeter();
        /*
        * 圆的面积和周长*/
        graph=new Rhomboid(2,3);
        graph.area();
        graph.perimeter();
        /*
        * 平行四边形的面积和周长*/
        graph=new Rectangle(2,3);
        graph.area();
        graph.perimeter();
        /*长方形的面积和周长*/
        graph=new Trapezoid(2,3,5,6,6);
        graph.area();
        graph.perimeter();
        /*梯形的面积和周长*/
    }
}
